package yxy.game.pm2.bean.db.po;


import yxy.apple.db.ResultObjectBuilder;

import java.util.Date;

public class PlainsCraftRecordPo {

    private String playerCode;
    private String code;//
    private Date date;// 时间
    private String recordCodes ;// 录像码  jsonarrary
    private boolean isWin;// 攻方是否胜利

    private String infoA;// 进攻方
    private String infoB;// 防守方
    private long updateTime;

    public static ResultObjectBuilder<PlainsCraftRecordPo> builder = rs -> {
        PlainsCraftRecordPo u = new PlainsCraftRecordPo();
        u.setPlayerCode(rs.getString("pCode"));
        u.setCode(rs.getString("code"));
        u.setDate(rs.getDate("date"));
        u.setRecordCodes(rs.getString("recordCodes"));
        u.setWin(rs.getBoolean("isWin"));
        u.setInfoA(rs.getString("infoA"));
        u.setInfoB(rs.getString("infoB"));
        u.setUpdateTime(rs.getLong("updateTime"));
        return u;
    };

    public String getPlayerCode() {
        return playerCode;
    }

    public void setPlayerCode(String playerCode) {
        this.playerCode = playerCode;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public Date getDate() {
        return date;
    }

    public void setDate(Date date) {
        this.date = date;
    }

    public String getRecordCodes() {
        return recordCodes;
    }

    public void setRecordCodes(String recordCodes) {
        this.recordCodes = recordCodes;
    }

    public static ResultObjectBuilder<PlainsCraftRecordPo> getBuilder() {
        return builder;
    }

    public static void setBuilder(ResultObjectBuilder<PlainsCraftRecordPo> builder) {
        PlainsCraftRecordPo.builder = builder;
    }

    public boolean isWin() {
        return isWin;
    }

    public void setWin(boolean win) {
        isWin = win;
    }

    public String getInfoA() {
        return infoA;
    }

    public void setInfoA(String infoA) {
        this.infoA = infoA;
    }

    public String getInfoB() {
        return infoB;
    }

    public void setInfoB(String infoB) {
        this.infoB = infoB;
    }

    public long getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(long updateTime) {
        this.updateTime = updateTime;
    }

    @Override
    public String toString() {
        return "PlainsCraftRecordPo{" +
                "playerCode='" + playerCode + '\'' +
                ", code='" + code + '\'' +
                ", date=" + date +
                ", recordCodes=" + recordCodes +
                ", isWin=" + isWin +
                ", infoA='" + infoA + '\'' +
                ", infoB='" + infoB + '\'' +
                ", updateTime=" + updateTime +
                '}';
    }
}
